package com.wb.spring.boot.autoconfigure.http;

import com.wb.spring.boot.autoconfigure.WbRpcAutoConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.ImportAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;


/**
 * @Author deeprado
 * @Date 2022/8/25 19:25
 */

@Configuration
@AutoConfigureAfter({WbRpcAutoConfiguration.class})
@ImportAutoConfiguration({
        WbOkHttpAutoConfiguration.class, WbHttpClientAutoConfiguration.class, WbDefaultHttpAutoConfiguration.class, WbAsyncClientAutoConfiguration.class})
public class WbClientAutoConfiguration {

    @Bean
    @ConditionalOnMissingBean
    public OKHttpProperties okHttpProperties() {
        return new OKHttpProperties();
    }

    @Bean
    @ConditionalOnMissingBean
    public HttpClientProperties httpClientProperties() {
        return new HttpClientProperties();
    }

}
